A System F with Call-by-Name Exceptions
نویسنده
چکیده
We present an extension of System F with call-by-name exceptions. The type system is enriched with two syntactic constructs: a union type A ? ∪{ε} for programs of type A whose execution may raise the exception ε at top level, and a corruption type A{ε} for programs that may raise the exception ε in any evaluation context (not necessarily at top level). We present the syntax and reduction rules of the system, as well as its typing and subtyping rules. We then study its properties, such as confluence. Finally, we construct a realizability model using orthogonality techniques, from which we deduce that well-typed programs are weakly normalizing and that the ones who have the type of natural numbers really compute a natural number, without raising exceptions.
منابع مشابه
A Type System For Call-By-Name Exceptions
We present an extension of System F with call-by-name exceptions. The type system is enriched with two syntactic constructs: a union type for programs whose execution may raise an exception at top level, and a corruption type for programs that may raise an exception in any evaluation context (not necessarily at top level). We present the syntax and reduction rules of the system, as well as its ...
متن کاملExceptions Are Strictly More Powerful Than Call/CC
We demonstrate that in the context of statically typed pure functional lambda calculi, exceptions are strictly more powerful than call/cc. More precisely, we prove that the simply typed lambda calculus extended with exceptions is strictly more powerful than Girard's F ! [6, 15] (a superset of the simply typed lambda calculus) extended with call/cc and abort. This result is established by showin...
متن کاملRe-imagining Research: A Bold Call, but Bold Enough?; Comment on “Experience of Health Leadership in Partnering with University-Based Researchers in Canada: A Call to ‘Re-Imagine’ Research”
Many articles over the last two decades have enumerated barriers to and facilitators for evidence use in health systems. Bowen et al’s article “Response to Experience of Health Leadership in Partnering with University-Based Researchers: A Call to ‘Re-imagine Research’” furthers the debate by focusing on an under-explored research area (health system design and health service organization) with ...
متن کاملContextual Equivalences in Call-by-Need and Call-By-Name Polymorphically Typed Calculi (Preliminary Report)
This paper presents a call-by-need polymorphically typed lambda-calculus with letrec, case, constructors and seq. The typing of the calculus is modelled in a system-F style. Contextual equivalence is used as semantics of expressions. We also define a call-by-name variant without letrec. We adapt several tools and criteria for recognizing correct program transformations to polymorphic typing, in...
متن کاملUnchecked Exceptions Can Be Strictly More Powerful Than Call/CC
We demonstrate that in the context of statically-typed purely-functional lambda calculi without recursion, unchecked exceptions (e.g., SML exceptions) can be strictly more powerful than call/cc. More precisely, we prove that a natural extension of the simply-typed lambda calculus with unchecked exceptions is strictly more powerful than all known sound extensions of Girard’s Fω (a superset of th...
متن کامل